package com.sfac.javaSpringBoot.modules.test.service;

import com.github.pagehelper.PageHelper;
import com.sfac.javaSpringBoot.modules.common.entity.Result;
import com.sfac.javaSpringBoot.modules.common.entity.SearchBean;
import com.sfac.javaSpringBoot.modules.test.entity.Student;
import org.springframework.data.domain.Page;

import java.util.List;

public interface StudentService {
    //    插入单条数据和编辑单条
    Result<Student> editStudent(Student student);

    //    删除单个数据
    Result<Object> DeleteStudentById(int id);

    //    单条件查询
    Student getStudentById(int id);

    //    查询全部
    List<Student> getStudents();

    //    多条件查询
    Student getStudentByNameAndEmail(String name, String email);


    Page<Student> getStudentsBySearchBean(SearchBean searchBean);


    Result<Object> insertStudents(List<Student> students);

}
